#ifndef GY_PENWIDTH_H
#define GY_PENWIDTH_H

#include "GY_ControlLibrary_global.h"
#include <QLabel>
#include <QPaintEvent>
#include <QPainter>

/** 自定义画笔的样式(点/线，粗细）
 * @brief The GY_PenWidth class
 */
class GY_CONTROLLIBRARY_EXPORT GY_PenWidth : public QLabel
{
    Q_OBJECT
public:
    explicit GY_PenWidth(QWidget* parent = nullptr);
    ~GY_PenWidth();

    void setDrawParameters(int drawType, int size);

protected:
    void paintEvent(QPaintEvent*) override;

private:
    int m_drawType; //绘制类型（画点/线）
    int m_size; //大小
};

#endif // GY_PENWIDTH_H
